Limit tooltip queries to the same native
authorMatthias Clasen <mclasen@redhat.com>
Thu, 11 Mar 2021 13:56:05 +0000 (08:56 -0500)
committerMatthias Clasen <mclasen@redhat.com>
Thu, 11 Mar 2021 13:56:56 +0000 (08:56 -0500)
Without this, the menubuttons tooltip pops up
when hovering the popover, which is suprising
and unintended.

Fixes: #3719
gtk/gtktooltip.c

index a192d1eb0dc5ea535298b1a5c31e9f03be7a9d3c..bb33088632ffa9202a2dca850b9819afd259345d 100644 (file)
@@ -548,6 +548,9 @@ gtk_tooltip_run_requery (GtkWidget  **widget,
               double xx = *x;
               double yy = *y;
 
+              if (gtk_widget_get_native (parent) != gtk_widget_get_native (*widget))
+                break;
+
               gtk_widget_translate_coordinates (*widget, parent, xx, yy, &xx, &yy);
 
               *x = xx;